<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<meta name="viewport" content="width=device-width,user-scalable=no, initial-scale=1">
		<link rel="stylesheet" type="text/css" href="//at.alicdn.com/t/font_835360_8flqp9ignrc.css"/>
		<link rel="stylesheet" type="text/css" href="/azxcrm/css/wap/aui.css" th:href="@{/azxcrm/css/wap/aui.css}" />
		<link rel="stylesheet" type="text/css" href="/azxcrm/css/wap/index.css" th:href="@{/azxcrm/css/wap/index.css}" />
		<link rel="stylesheet" type="text/css" href="/azxcrm/css/wap/customer.css" th:href="@{/azxcrm/css/wap/customer.css}" />
		<script src="../static/js/jquery.min.js" th:src="@{/js/jquery.min.js}"></script>
	</head>	

<header class="aui-bar aui-bar-nav">
    <div class="aui-title">客户</div>
    <a th:href="@{/wap/customer/addCustomer}" class="aui-pull-right aui-btn aui-btn-outlined">
        <span id="add">添加客户</span>
    </a>
</header>
<div class="aui-warp">
	<div class="aui-searchbar" id="search">
	    <div class="aui-searchbar-input aui-border-radius">
	        <i class="iconfont icon-sousuo"></i>
	        <form action="javascript:search();">
           		 <input type="search" name="searchValue" placeholder="请输入搜索内容" id="search-input" oninput="doSearch()">
       		 </form>
	    </div>   
	    <div class="aui-searchbar-cancel" tapmod>取消</div>
	</div>
	<div class="aui-card-list">      
	    <div class="aui-card-list-content">
	        <ul class="aui-list aui-media-list" >
	            <li class="aui-list-item aui-list-item-middle" th:each="clueList : ${clue}">
	                <a th:href="@{/wap/customer/customerInfo(clueId=${clueList.clueId},status=2)}" class="aui-media-list-item-inner">
	                    <div class="aui-list-item-media">
	                        <img src="../azxcrm/image/wap/moren.jpg" alt="image" class="aui-img-round aui-list-img-sm">
	                    </div>
	                    <div class="aui-list-item-inner aui-list-item-arrow">
	                        <div class="aui-list-item-text">
	                            <div class="aui-list-item-title aui-font-size-14">
	                            <span th:text="${clueList.customerName}"></span> 
	                            <span th:if="${clueList.customerSex}==2" class="iconfont icon-nv sex woman"></span>
	                            <span th:if="${clueList.customerSex}==1" class="iconfont icon-82 sex male"></span></div>                           
	                        </div>  
	                        <div class="aui-list-item-text">
	                              <span th:text="${clueList.customerCellphone}"></span>
	                        </div>
	                    </div>
	                </a>
	            </li>
	        </ul>
	    </div>
	</div>
</div>  
<footer class="aui-bar aui-bar-tab" id="footer">
	<a th:href="@{/indexWap}" class="aui-bar-tab-item">
		<i class="iconfont icon-cangku"></i>          
		<div class="aui-bar-tab-label">工作台</div>
	</a>
	<a class="aui-bar-tab-item aui-active">
		<i class="iconfont icon-qunzu"></i>          
		<div class="aui-bar-tab-label">客户</div>
	</a>
	<a th:href="@{/wap/wapMy}" class="aui-bar-tab-item">          
		<i class="iconfont icon-gerentouxiang"></i>         
		<div class="aui-bar-tab-label">我的</div>
	</a>        
</footer>
<script type="text/javascript">

var searchBar = document.querySelector(".aui-searchbar-input");
    searchBar.onclick = function(){  
        document.querySelector(".aui-searchbar-cancel").style.marginRight = 10;
      
    }

document.querySelector(".aui-searchbar-cancel").onclick = function(){
	document.querySelector('.aui-searchbar-cancel').style.display='none';
    document.getElementById("search-input").blur();
    document.getElementById("search-input").value = '';
    $('.aui-list-item-text').siblings('.aui-list-item-text').parents('.aui-list-item-middle').css('display','block');
}
function doSearch(){
	$(".aui-searchbar-cancel").css('display','block');
    var Value = document.getElementById("search-input").value;
    if(Value){
    	$('.aui-list-item-text').siblings('.aui-list-item-text').parents('.aui-list-item-middle').css('display','none');
    	$('.aui-list-item-text:contains('+ Value +')').parents('.aui-list-item-middle').css('display','block')
    }
   
}	
</script>
<script th:inline="javascript"> var ctx = [[@{/}]]; </script>
<script src="../static/azxcrm/js/wap/customer.js" th:src="@{/azxcrm/js/wap/customer.js}"></script>